]> dgit.raspbian.org Git - gnome-shell.git/commitdiff
keyboard: Update OSK key model from JSON to new format
authorCarlos Garnacho <carlosg@gnome.org>
Wed, 13 Apr 2022 14:54:59 +0000 (16:54 +0200)
committerFlorian Müllner <fmuellner@gnome.org>
Wed, 10 Aug 2022 17:11:26 +0000 (17:11 +0000)
Every key is now a map able to handle more properties, so its behavior
can be extended. For now, minimally adapt to the new format so the OSK
does not break along the update.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/2278>

js/ui/keyboard.js

index 77a6f7d5cc64449a4f9f13b3ec90ab8eb3801bc7..fc4c0c59ef6a73856202ae6b2d4e8e32c9c6ac97 100644 (file)
@@ -1511,7 +1511,8 @@ var Keyboard = GObject.registerClass({
     _addRowKeys(keys, layout) {
         for (let i = 0; i < keys.length; ++i) {
             let key = keys[i];
-            let button = new Key(key.shift(), key);
+            const {strings} = key;
+            let button = new Key(strings.shift(), strings);
 
             /* Space key gets special width, dependent on the number of surrounding keys */
             if (button.key == ' ')